﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="InjectPINsToDB.aspx.cs" Inherits="MMITPinGen.InjectPINsToDB1" %>
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <style type="text/css">


        .style1
        {
            width: 100%;
        }
    
.bold
{
    font-weight: bold;
}

a:link, a:visited
{
    color: #034af3;
}

a:link
{
    color: #034af3;
}

        #tblForm
        {
            width: 519px;
        }
    </style>
    <link href="http://localhost:27665/Styles/Site.css" rel="stylesheet" 
        type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
   <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
    </telerik:RadScriptManager>
    <div>
     <asp:HyperLink ID="lnkHome" runat="server" NavigateUrl="~/Default.aspx">Home</asp:HyperLink>
        <table class="style1">
            <tr>
                <td align="center">
                    <asp:Label ID="lblMsg" runat="server" CssClass="bold"></asp:Label>
                    <telerik:RadButton ID="lnkNew" runat="server" ButtonType="LinkButton" 
                        Text="Click Here to Generate New Batch" Visible="False" 
                        onclick="lnkNew_Click" SplitButtonCssClass="" SplitButtonPosition="Right">
                    </telerik:RadButton>
                </td>
            </tr>
            <tr>
                <td align="center">
    <telerik:RadGrid ID="grdBatches" runat="server" AutoGenerateColumns="False" 
        GridLines="None"   OnSelectedIndexChanged="grdBatches_SelectedIndexChanged" 
                        datakeynames="Id" Width="600px" 
                        >
<MasterTableView>
<CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings>

<RowIndicatorColumn>
<HeaderStyle Width="20px"></HeaderStyle>
</RowIndicatorColumn>

<ExpandCollapseColumn>
<HeaderStyle Width="20px"></HeaderStyle>
</ExpandCollapseColumn>
    <Columns>
       
        <telerik:GridButtonColumn DataTextField="Name" UniqueName="Name" 
            HeaderText="Name" CommandName="Select">
        </telerik:GridButtonColumn>
        
     <telerik:GridTemplateColumn UniqueName="Status" HeaderText="Status">
        <ItemTemplate>
            <%--<asp:CheckBox ID="CheckBox1" runat="server" Checked='<%# Convert.ToBoolean(DataBinder.Eval(Container.DataItem, "Status"))  %>'  Enabled=false/>--%>
            <asp:HiddenField ID="HiddenField1" runat="server" Value='<%# DataBinder.Eval(Container.DataItem, "Id")  %>' />
            </ItemTemplate>
        </telerik:GridTemplateColumn>


         <telerik:GridBoundColumn DataField="Quantity" HeaderText="Quantity" 
            UniqueName="column1">
        </telerik:GridBoundColumn>
        <telerik:GridBoundColumn DataField="Value" HeaderText="Voucher Value" 
            UniqueName="column2">
        </telerik:GridBoundColumn>



         <telerik:GridTemplateColumn UniqueName="DateGenerated" HeaderText="Date and Time Generated">
        <ItemTemplate>
            <%--<asp:CheckBox ID="CheckBox1" runat="server" Checked='<%# Convert.ToBoolean(DataBinder.Eval(Container.DataItem, "Status"))  %>'  Enabled=false/>--%>
            <asp:Label ID="Label1" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "DateGenerated", "{0:dd MMM yyyy hh:mm}")  %>'  ></asp:Label>
            </ItemTemplate>
        </telerik:GridTemplateColumn>
        
       <%-- <telerik:GridBoundColumn DataField='<%# DataBinder.Eval(Container.DataItem, "DateGenerated", "{0:dd MMM yyyy}")  %>' HeaderText="Date Generated" 
            UniqueName="column">
        </telerik:GridBoundColumn>--%>
       

        
    </Columns>
</MasterTableView>

<HeaderContextMenu EnableImageSprites="True" CssClass="GridContextMenu GridContextMenu_Default"></HeaderContextMenu>
    </telerik:RadGrid>
                </td>
            </tr>
            <tr>
                <td>
    
                    &nbsp;</td>
            </tr>
            <tr>
                <td>
                    &nbsp;</td>
            </tr>
        </table>
    
    </div>
    </form>
</body>
</html>
